package com.huaju.enity;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;

import static javax.persistence.GenerationType.IDENTITY;

import javax.persistence.Id;
import javax.persistence.Table;

import org.springframework.format.annotation.DateTimeFormat;

import com.fasterxml.jackson.annotation.JsonFormat;

/**
 * Adminlog entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "adminlog", catalog = "licai")
public class Adminlog implements java.io.Serializable {

	// Fields

	private Integer lid;
	private Date logTime;
	private String logMsg;
	private String logUser;
	private String logType;
	private Short isSuccess;

	// Constructors

	/** default constructor */
	public Adminlog() {
	}

	/** full constructor */
	public Adminlog(Date logTime, String logMsg, String logUser,
			String logType, Short isSuccess) {
		this.logTime = logTime;
		this.logMsg = logMsg;
		this.logUser = logUser;
		this.logType = logType;
		this.isSuccess = isSuccess;
	}

	// Property accessors
	@Id
	@GeneratedValue(strategy = IDENTITY)
	@Column(name = "lid", unique = true, nullable = false)
	public Integer getLid() {
		return this.lid;
	}

	public void setLid(Integer lid) {
		this.lid = lid;
	}

	@Column(name = "logTime", length = 19)
    @DateTimeFormat(pattern="yyyy-MM-dd" ) 
    @JsonFormat(pattern="yyyy-MM-dd" ,timezone = "GMT+8")
	public Date getLogTime() {
		return this.logTime;
	}

	public void setLogTime(Date logTime) {
		this.logTime = logTime;
	}

	@Column(name = "logMsg", length = 65535)
	public String getLogMsg() {
		return this.logMsg;
	}

	public void setLogMsg(String logMsg) {
		this.logMsg = logMsg;
	}

	@Column(name = "logUser")
	public String getLogUser() {
		return this.logUser;
	}

	public void setLogUser(String logUser) {
		this.logUser = logUser;
	}

	@Column(name = "logType")
	public String getLogType() {
		return this.logType;
	}

	public void setLogType(String logType) {
		this.logType = logType;
	}

	@Column(name = "isSuccess")
	public Short getIsSuccess() {
		return this.isSuccess;
	}

	public void setIsSuccess(Short isSuccess) {
		this.isSuccess = isSuccess;
	}

}